<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<title>上传</title>
	<!-- <link rel="icon" href="http://cart.en.jd.com/cart/favicon.ico" type="image/x-icon" />
	<link rel="shortcut icon" href="http://cart.en.jd.com/cart/favicon.ico" type="image/x-icon" /> -->
	<link media="all" href="<c:url value="/css/base.css"/>" type="text/css" rel="stylesheet"/>
	<link media="all" href="<c:url value="/css/cart.css"/>" type="text/css" rel="stylesheet"/>
	<script src="<c:url value="/js/jquery-1.2.6.js"/>" type="text/javascript"></script>
	<script language="javascript" src="<c:url value="/js/config2.js"/>"></script>
	<script language="javascript" src="<c:url value="/js/common.js"/>"></script>
	<script language="javascript" src="<c:url value="/js/template.js"/>"></script>

</head>
<body>
	<script src="<c:url value="/js/base-v1.js"/>" type="text/javascript"></script>
	
	<script type="text/javascript">
		function saveEntity(){
			var name = document.getElementById("name").value;
			var price = document.getElementById("price").value;
			var year = document.getElementById("year").value;
			var origin = document.getElementById("origin").value;
			var proportion = document.getElementById("proportion").value;
			var longtitude = document.getElementById("longtitude").value;
			var latitude = document.getElementById("latitude").value;
			var country = document.getElementById("country").value;
			var district = document.getElementById("district").value;
			var state = document.getElementById("state").value;
			var city = document.getElementById("city").value;
			var resolution = document.getElementById("resolution").value;

			var data = {"categoryName": name, "categoryPrice": price, "categoryYear": year, "categoryResolution": resolution, 
					"categoryOrigin": origin, "categoryProportion": proportion, "categoryLongtitude": longtitude, "categoryLatitude": latitude, 
					"categoryCountry": country, "categoryArea": district, "categoryProvince": state, "categoryCity": city};

			 $.ajax({
		        	type: "POST",
		            url: "/RemoteSensing/image/saveEntity.action?random=" + Math.random(),
		            dataType: "json",
		            data: JSON.stringify(data),
		            contentType:"application/json",
		            success: function(result) {
		                if (result.ERROR) {
			                alert(result.ERROR);
		                }
		            }
			 });
		}
	</script>
	
	<jsp:include page="/jsp/shortcut.jsp" />

	<div class="cart-header w">
		<div class="logo">
			<a href="<c:url value="/category/home.html"/>" rel="nofollow">
				<img src="<c:url value="/img/logo.png"/>" height="50" width="176" />
			</a>
		</div>
	</div>

	<div class="cart w">
		<div id="show">
			
			<div id="order_jst">
				<div class="cart-list">
					<div class="cart-com">
						
						<div id="edit_consignee">
							<div class="mc">
								<div class="mct">
									<em>*</em>影像名称:
								</div>
								<div class="mcc">
									<input type="text" class="cinp cinp2" value="" id="name"/>
								</div>
								<div class="mct">
									<em>*</em>价格:
								</div>
								<div class="mcc">
									<input type="text" class="cinp cinp1" value="" id="price" />
								</div>
								<div class="mct">
									<em>*</em>分辨率:
								</div>
								<div class="mcc">
									<input type="text" class="cinp cinp1" value="" id="resolution" />
								</div>
								<div class="mct">
									<em>*</em>时像:
								</div>
								<div class="mcc">
									<input type="text" class="cinp cinp1" value="" id="year" />
								</div>
								<div class="mct">
									<em>*</em>数据来源:
								</div>
								<div class="mcc">
									<input type="text" class="cinp cinp1" value="" id="origin" />
								</div>
								<div class="mct">
									<em>*</em>覆盖面积:
								</div>
								<div class="mcc">
									<input type="text" class="cinp cinp1" value="" id="proportion" />
								</div>
								<div class="mct">
									<em>*</em>经度:
								</div>
								<div class="mcc">
									<input type="text" class="cinp cinp1" value="" id="longtitude" />
								</div>
								<div class="mct">
									<em>*</em>纬度:
								</div>
								<div class="mcc">
									<input type="text" class="cinp cinp1" value="" id="latitude" />
								</div>
								<div class="mct">
									<em>*</em>国家：
								</div>
								<div class="mcc">
									<select class="city" id="country">
										<option value="-22">请选择</option>
										<option value="3">中国</option>
									</select>
								</div>
								<div class="mct">
									<em>*</em>地区：
								</div>
								<div class="mcc">
									<div id="div_District">
										<select class="city" id="district">
											<option value="-22">请选择</option>
											<option value="2">京津冀晋内蒙古</option>
											<option value="4">川 云贵藏渝</option>
											<option value="5">粤桂琼台港澳</option>
											<option value="6">豫鄂湘</option>
											<option value="7">陕甘青宁新</option>
											<option value="8">鲁皖苏赣浙闽沪</option>
											<option value="9">黑吉辽</option>
										</select>
									</div>
								</div>
								<div class="mct">
									<em>*</em>省份：
								</div>
								<div class="mcc">
									<div id="div_State">
										<select class="state"  onchange="changeState(this)" id="state">
											<option value="-22">请选择</option>
										</select>
									</div>
								</div>
								<div class="mct">
									<em>*</em>城市：
								</div>
								<div class="mcc">
									<div id="div_City">
										<select class="city" id="city">
											<option value="-22">请选择</option>
										</select>
									</div>
								</div>
								<div class="mct"></div>
								<div class="mcc">
									<input type="button" class="btn-add1" value="提交" onclick="saveEntity()" id="save"/>
								</div>
					
					
							</div>
						</div>
						
						
					</div>
				</div>
				<span class="clr"></span>
			</div>
		
					
		</div>
	</div>
	<jsp:include page="/jsp/bottom.jsp"/>

	<script src="<c:url value="/js/lib-v1.js"/>" type="text/javascript"> </script>



</body>
</html>
